package com.by.config;

import com.by.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;

/**
 * @author LittleDesire
 * @description
 * @date 2022-03-23 周三 9:03
 * @since 17
 */
@Configuration
@ComponentScan("com.by.pojo")
@Import({DruidConfig.class})
public class ApplicationConfig {


    @Bean("zs")
    public User zs() {
        User user = new User();
        user.setId(123);
        user.setName("张三");
        return user;
    }
    @Bean("ls")
    public User ls() {
        User user = new User();
        user.setId(123123);
        user.setName("李四");
        return user;
    }
}
